package com.dy.cloud.service;

import com.dy.cloud.pojo.Entity.PaymentEntity;
import com.dy.cloud.util.ApiResousUtil;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @ClassName:
 * @Author: 仄言in
 * @Desctiption: (描述)
 * @Date: 2021/9/15 8:59
 * @Version 1.0 (版本)
 */
@FeignClient(value = "CLOUDPROVIDERPAYMENT")
public interface PaymentFeignService {
    /**
     * 全查询
     * @return
     **/
    @GetMapping("/payment/list")
    public ApiResousUtil list();
    /**
     * 添加
     * @param payment
     * @return
     **/
    @PostMapping("/payment/save")
    public ApiResousUtil save(@RequestBody PaymentEntity payment);
    /**
     * 删除
     * @param id
     * @return
     **/
    @GetMapping("/payment/deleteById/{id}")
    public ApiResousUtil<String> deleteById(@PathVariable("id") Long id);
    /**
     * 根据id查询
     * @param id
     * @return
     **/
    @GetMapping("/payment/selectById/{id}")
    public ApiResousUtil<String> selectById(@PathVariable("id") Long id);
    /**
     * 更新
     * @param payment
     * @return
     **/
    @PostMapping("/payment/updateById")
    public ApiResousUtil<String> updateById(@RequestBody PaymentEntity payment);
    /**
     * 查询服务信息
     * @return
     **/
    @GetMapping("/payment/discovery")
    public Object discovery();
}
